/**
 * Created by Dalyn on 2017/4/11.
 */
import Relay from "react-relay";

export default class GetEnOrderTypeMutation extends Relay.Mutation {

    static fragments = {};

    getMutation() {
        return Relay.QL`mutation { getEnOrderType }`;
    }

    getVariables() {
        return {
            argsInput: {
                enId: this.props.enId,
            }
        };
    }

    getFatQuery() {
        return Relay.QL`fragment on getEnOrderTypePayload {
            getEnOrderType {
                errorCode
                value
                totalResult
                id
                enOrderType{
                   ordertype
                   enId
                   eid
                }
            }
        }`;
    }

    getConfigs() {
        return [{
            type: 'REQUIRED_CHILDREN',
            children: [Relay.QL`
              fragment on getEnOrderTypePayload {
                    getEnOrderType {
                        errorCode
                        value
                        totalResult
                        id
                        enOrderType{
                           ordertype
                           enId
                           eid
                        }
                    }
                }
            `]
        }];
    }

}
